package com.ruoyi.medical.service.impl;

import com.ruoyi.medical.domain.MeiomsDeviceType;
import com.ruoyi.medical.mapper.MeiomsDeviceTypeMapper;
import com.ruoyi.medical.service.IMeiomsDeviceTypeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 设备类型Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-12-03
 */
@Service
public class MeiomsDeviceTypeServiceImpl implements IMeiomsDeviceTypeService
{
    @Autowired
    private MeiomsDeviceTypeMapper meiomsDeviceTypeMapper;

    /**
     * 查询设备类型
     * 
     * @param typeId 设备类型主键
     * @return 设备类型
     */
    @Override
    public MeiomsDeviceType selectMeiomsDeviceTypeByTypeId(Long typeId)
    {
        return meiomsDeviceTypeMapper.selectMeiomsDeviceTypeByTypeId(typeId);
    }

    /**
     * 查询设备类型列表
     * 
     * @param meiomsDeviceType 设备类型
     * @return 设备类型集合
     */
    @Override
    public List<MeiomsDeviceType> selectMeiomsDeviceTypeList(MeiomsDeviceType meiomsDeviceType)
    {
        return meiomsDeviceTypeMapper.selectMeiomsDeviceTypeList(meiomsDeviceType);
    }

    /**
     * 新增设备类型
     * 
     * @param meiomsDeviceType 设备类型
     * @return 结果
     */
    @Override
    public int insertMeiomsDeviceType(MeiomsDeviceType meiomsDeviceType)
    {
        return meiomsDeviceTypeMapper.insertMeiomsDeviceType(meiomsDeviceType);
    }

    /**
     * 修改设备类型
     * 
     * @param meiomsDeviceType 设备类型
     * @return 结果
     */
    @Override
    public int updateMeiomsDeviceType(MeiomsDeviceType meiomsDeviceType)
    {
        return meiomsDeviceTypeMapper.updateMeiomsDeviceType(meiomsDeviceType);
    }

    /**
     * 批量删除设备类型
     * 
     * @param typeIds 需要删除的设备类型主键集合
     * @return 结果
     */
    @Override
    public int deleteMeiomsDeviceTypeByTypeIds(Long[] typeIds)
    {
        return meiomsDeviceTypeMapper.deleteMeiomsDeviceTypeByTypeIds(typeIds);
    }

    /**
     * 删除设备类型信息
     * 
     * @param typeId 设备类型主键
     * @return 结果
     */
    @Override
    public int deleteMeiomsDeviceTypeByTypeId(Long typeId)
    {
        return meiomsDeviceTypeMapper.deleteMeiomsDeviceTypeByTypeId(typeId);
    }
}
